<?php
    $table = new CI_Table();
    
    $table->set_template(array(
        'table_open'=>'<table width="450" id="contractTypeStaticTable" border="1">'
    ));
    $table->set_heading(
            'Contract Type',
            'All',
            'Renewal 45 days'
            );
    $allStatic = ContractUtil::getContractTypeCountStatic();
    $expiredStatic = ContractUtil::getContractTypeExpiredStatic();    
    
    foreach($allStatic as $type=>$static){
        $table->add_row(
                $type,
                array(
                    'data'=>$allStatic[$type],
                 
                ),
                CHtml::link($expiredStatic[$type],array(
                    'contractCenter/renewalCenter','type'=>$type
                ))
                );
    }
    echo $table->generate();
    ?>
